<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">

<title>class YARP::Serialize::Loader - yarp: Ruby Standard Library Documentation</title>


<script src="../../js/navigation.js" defer></script>
<script src="../../js/search.js" defer></script>
<script src="../../js/search_index.js" defer></script>
<script src="../../js/searcher.js" defer></script>
<script src="../../js/darkfish.js" defer></script>

<script src="../../js/jquery-3.2.0.min.js"></script>

<script src="../../js/vue.min.js"></script>
<script src="../../js/js.cookie.min.js"></script>

<link href="../../css/fonts.css" rel="stylesheet">
<link id='rdoccss' href="../../css/rdoc.css" rel="stylesheet">
<link href="../../css/carbon17.css" rel="stylesheet">

<script type="text/javascript">
  var rdoc_rel_prefix = "../../";
  var index_rel_prefix = "../../";
  var darkModeCsseHref = "../../css/rdoc-dm.css"
  var defaultModeCssHref = "../../css/rdoc.css"
  // var cssDarkmode = Cookies.get('darkmode');
  
  if( Cookies.get("darkmode") == "true") {
	$('#rdoccss').attr("href", darkModeCsseHref);
}

//  https://cssdeck.com/blog/simple-jquery-stylesheet-switcher/

document.write('<style type="text/css">body{display:none}</style>');

</script>


</head>
<body id="top" role="document" class="class">
  <!-- this is class.html -->

  <div id='actionbar' >
    <div class='wrapper mdiv'>
      <ul class='grids g0'></ul>
    </div> 
    <!-- VERSION HEADER for 3.3.0.preview2 NOT FOUND -->
  </div> <!-- end action bar -->

  <div class='wrapper hdiv'>

    


    <nav id='vapp' role="navigation">
    <div id="project-navigation">
      <div id="home-section" role="region" title="Quick navigation" class="nav-section">
  <h2><a href="../../index.html" rel="home">Home</a></h2>

  <div id="table-of-contents-navigation"  >
    <a href="../../table_of_contents.html#pages">Pages</a>
    <a href="../../table_of_contents.html#classes">Classes</a>
    <a href="../../table_of_contents.html#methods">Methods</a>
  </div>
</div>

      <div id="search-section" role="search" class="project-section initially-hidden">
  <form action="#" method="get" accept-charset="utf-8">
    <div id="search-field-wrapper">
      <input id="search-field" role="combobox" aria-label="Search"
             aria-autocomplete="list" aria-controls="search-results"
             type="text" name="search" placeholder="Search" spellcheck="false"
             title="Type to search, Up and Down to navigate, Enter to load">
    </div>

    <ul id="search-results" aria-label="Search Results"
        aria-busy="false" aria-expanded="false"
        aria-atomic="false" class="initially-hidden"></ul>
  </form>
</div>

    </div>


    

    <button id='toggleThing' @click="toggleNav()" >Show/hide navigation</button>
    <div :class="isOpen ? 'block' : 'hidden' " id='toggleMe'>
      <div id="class-metadata">
        
        
<div id="parent-class-section" class="nav-section">
  <h3>Parent</h3>

  <p class="link"><a href="../../Object.html">Object</a>
</div>

        
        
        
<!-- Method Quickref -->
<div id="method-list-section" class="nav-section">
  <h3>Methods</h3>

  <ul class="link-list" role="directory">
    <li ><a href="#method-c-new">::new</a>
    <li ><a href="#method-i-load_constant">#load_constant</a>
    <li ><a href="#method-i-load_embedded_string">#load_embedded_string</a>
    <li ><a href="#method-i-load_encoding">#load_encoding</a>
    <li ><a href="#method-i-load_location">#load_location</a>
    <li ><a href="#method-i-load_metadata">#load_metadata</a>
    <li ><a href="#method-i-load_node">#load_node</a>
    <li ><a href="#method-i-load_nodes">#load_nodes</a>
    <li ><a href="#method-i-load_optional_constant">#load_optional_constant</a>
    <li ><a href="#method-i-load_optional_location">#load_optional_location</a>
    <li ><a href="#method-i-load_optional_node">#load_optional_node</a>
    <li ><a href="#method-i-load_required_constant">#load_required_constant</a>
    <li ><a href="#method-i-load_result">#load_result</a>
    <li ><a href="#method-i-load_serialized_length">#load_serialized_length</a>
    <li ><a href="#method-i-load_string">#load_string</a>
    <li ><a href="#method-i-load_tokens">#load_tokens</a>
    <li ><a href="#method-i-load_tokens_result">#load_tokens_result</a>
    <li ><a href="#method-i-load_varint">#load_varint</a>
  </ul>
</div>

      </div>
     </div>
    </nav>


    <div id='extraz'><div class='adzbox-index'  >
      
     </div>         
    </div>

    <main role="main" aria-labelledby="class-YARP::Serialize::Loader">
    <h1 id="class-YARP::Serialize::Loader" class="class">
      class YARP::Serialize::Loader
    </h1>

    <section class="description">
    
    </section>

      <section id="5Buntitled-5D" class="documentation-section">



        <section class="attribute-method-details" class="method-section">
        <header>
        <h3>Attributes</h3>
        </header>

          <div id="attribute-i-constant_pool" class="method-detail">
            <div class="method-heading attribute-method-heading">
              <span class="method-name">constant_pool</span><span
                class="attribute-access-type">[R]</span>
            </div>

            <div class="method-description">
              
              </div>
            </div>
          <div id="attribute-i-constant_pool_offset" class="method-detail">
            <div class="method-heading attribute-method-heading">
              <span class="method-name">constant_pool_offset</span><span
                class="attribute-access-type">[R]</span>
            </div>

            <div class="method-description">
              
              </div>
            </div>
          <div id="attribute-i-encoding" class="method-detail">
            <div class="method-heading attribute-method-heading">
              <span class="method-name">encoding</span><span
                class="attribute-access-type">[R]</span>
            </div>

            <div class="method-description">
              
              </div>
            </div>
          <div id="attribute-i-input" class="method-detail">
            <div class="method-heading attribute-method-heading">
              <span class="method-name">input</span><span
                class="attribute-access-type">[R]</span>
            </div>

            <div class="method-description">
              
              </div>
            </div>
          <div id="attribute-i-io" class="method-detail">
            <div class="method-heading attribute-method-heading">
              <span class="method-name">io</span><span
                class="attribute-access-type">[R]</span>
            </div>

            <div class="method-description">
              
              </div>
            </div>
          <div id="attribute-i-serialized" class="method-detail">
            <div class="method-heading attribute-method-heading">
              <span class="method-name">serialized</span><span
                class="attribute-access-type">[R]</span>
            </div>

            <div class="method-description">
              
              </div>
            </div>
          <div id="attribute-i-source" class="method-detail">
            <div class="method-heading attribute-method-heading">
              <span class="method-name">source</span><span
                class="attribute-access-type">[R]</span>
            </div>

            <div class="method-description">
              
              </div>
            </div>
            </section>


                <section id="public-class-5Buntitled-5D-method-details" class="method-section">
                <header>
                <h3>Public Class Methods</h3>
                </header>

                  <div id="method-c-new" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">new</span><span
                                class="method-args">(source, serialized)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="new-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 45</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">initialize</span>(<span class="ruby-identifier">source</span>, <span class="ruby-identifier">serialized</span>)
  <span class="ruby-ivar">@encoding</span> = <span class="ruby-constant">Encoding</span><span class="ruby-operator">::</span><span class="ruby-constant">UTF_8</span>

  <span class="ruby-ivar">@input</span> = <span class="ruby-identifier">source</span>.<span class="ruby-identifier">source</span>.<span class="ruby-identifier">dup</span>
  <span class="ruby-ivar">@serialized</span> = <span class="ruby-identifier">serialized</span>
  <span class="ruby-ivar">@io</span> = <span class="ruby-constant">StringIO</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">serialized</span>)
  <span class="ruby-ivar">@io</span>.<span class="ruby-identifier">set_encoding</span>(<span class="ruby-constant">Encoding</span><span class="ruby-operator">::</span><span class="ruby-constant">BINARY</span>)

  <span class="ruby-ivar">@constant_pool_offset</span> = <span class="ruby-keyword">nil</span>
  <span class="ruby-ivar">@constant_pool</span> = <span class="ruby-keyword">nil</span>

  <span class="ruby-ivar">@source</span> = <span class="ruby-identifier">source</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                          </section>

                <section id="public-instance-5Buntitled-5D-method-details" class="method-section">
                <header>
                <h3>Public Instance Methods</h3>
                </header>

                  <div id="method-i-load_encoding" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_encoding</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_encoding-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 59</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_encoding</span>
  <span class="ruby-constant">Encoding</span>.<span class="ruby-identifier">find</span>(<span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>(<span class="ruby-identifier">load_varint</span>))
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_metadata" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_metadata</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_metadata-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 63</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_metadata</span>
  <span class="ruby-identifier">comments</span> = <span class="ruby-identifier">load_varint</span>.<span class="ruby-identifier">times</span>.<span class="ruby-identifier">map</span> { <span class="ruby-constant">Comment</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Comment</span><span class="ruby-operator">::</span><span class="ruby-constant">TYPES</span>.<span class="ruby-identifier">fetch</span>(<span class="ruby-identifier">load_varint</span>), <span class="ruby-identifier">load_location</span>) }
  <span class="ruby-identifier">errors</span> = <span class="ruby-identifier">load_varint</span>.<span class="ruby-identifier">times</span>.<span class="ruby-identifier">map</span> { <span class="ruby-constant">ParseError</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_embedded_string</span>, <span class="ruby-identifier">load_location</span>) }
  <span class="ruby-identifier">warnings</span> = <span class="ruby-identifier">load_varint</span>.<span class="ruby-identifier">times</span>.<span class="ruby-identifier">map</span> { <span class="ruby-constant">ParseWarning</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_embedded_string</span>, <span class="ruby-identifier">load_location</span>) }
  [<span class="ruby-identifier">comments</span>, <span class="ruby-identifier">errors</span>, <span class="ruby-identifier">warnings</span>]
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_nodes" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_nodes</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_nodes-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 96</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_nodes</span>
  <span class="ruby-identifier">raise</span> <span class="ruby-string">&quot;Invalid serialization&quot;</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>(<span class="ruby-value">4</span>) <span class="ruby-operator">!=</span> <span class="ruby-string">&quot;YARP&quot;</span>
  <span class="ruby-identifier">raise</span> <span class="ruby-string">&quot;Invalid serialization&quot;</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>(<span class="ruby-value">3</span>).<span class="ruby-identifier">unpack</span>(<span class="ruby-string">&quot;C3&quot;</span>) <span class="ruby-operator">!=</span> [<span class="ruby-constant">MAJOR_VERSION</span>, <span class="ruby-constant">MINOR_VERSION</span>, <span class="ruby-constant">PATCH_VERSION</span>]

  <span class="ruby-ivar">@encoding</span> = <span class="ruby-identifier">load_encoding</span>
  <span class="ruby-ivar">@input</span> = <span class="ruby-identifier">input</span>.<span class="ruby-identifier">force_encoding</span>(<span class="ruby-ivar">@encoding</span>).<span class="ruby-identifier">freeze</span>

  <span class="ruby-identifier">comments</span>, <span class="ruby-identifier">errors</span>, <span class="ruby-identifier">warnings</span> = <span class="ruby-identifier">load_metadata</span>

  <span class="ruby-ivar">@constant_pool_offset</span> = <span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>(<span class="ruby-value">4</span>).<span class="ruby-identifier">unpack1</span>(<span class="ruby-string">&quot;L&quot;</span>)
  <span class="ruby-ivar">@constant_pool</span> = <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>, <span class="ruby-keyword">nil</span>)

  [<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">comments</span>, <span class="ruby-identifier">errors</span>, <span class="ruby-identifier">warnings</span>]
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_result" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_result</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_result-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 111</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_result</span>
  <span class="ruby-identifier">node</span>, <span class="ruby-identifier">comments</span>, <span class="ruby-identifier">errors</span>, <span class="ruby-identifier">warnings</span> = <span class="ruby-identifier">load_nodes</span>
  <span class="ruby-constant">YARP</span><span class="ruby-operator">::</span><span class="ruby-constant">ParseResult</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">node</span>, <span class="ruby-identifier">comments</span>, <span class="ruby-identifier">errors</span>, <span class="ruby-identifier">warnings</span>, <span class="ruby-ivar">@source</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_tokens" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_tokens</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_tokens-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 70</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_tokens</span>
  <span class="ruby-identifier">tokens</span> = []
  <span class="ruby-keyword">while</span> <span class="ruby-identifier">type</span> = <span class="ruby-constant">TOKEN_TYPES</span>.<span class="ruby-identifier">fetch</span>(<span class="ruby-identifier">load_varint</span>)
    <span class="ruby-identifier">start</span> = <span class="ruby-identifier">load_varint</span>
    <span class="ruby-identifier">length</span> = <span class="ruby-identifier">load_varint</span>
    <span class="ruby-identifier">lex_state</span> = <span class="ruby-identifier">load_varint</span>
    <span class="ruby-identifier">location</span> = <span class="ruby-constant">Location</span>.<span class="ruby-identifier">new</span>(<span class="ruby-ivar">@source</span>, <span class="ruby-identifier">start</span>, <span class="ruby-identifier">length</span>)
    <span class="ruby-identifier">tokens</span> <span class="ruby-operator">&lt;&lt;</span> [<span class="ruby-constant">YARP</span><span class="ruby-operator">::</span><span class="ruby-constant">Token</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">type</span>, <span class="ruby-identifier">location</span>.<span class="ruby-identifier">slice</span>, <span class="ruby-identifier">location</span>), <span class="ruby-identifier">lex_state</span>]
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">tokens</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_tokens_result" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_tokens_result</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_tokens_result-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 83</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_tokens_result</span>
  <span class="ruby-identifier">tokens</span> = <span class="ruby-identifier">load_tokens</span>
  <span class="ruby-identifier">encoding</span> = <span class="ruby-identifier">load_encoding</span>
  <span class="ruby-identifier">comments</span>, <span class="ruby-identifier">errors</span>, <span class="ruby-identifier">warnings</span> = <span class="ruby-identifier">load_metadata</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">encoding</span> <span class="ruby-operator">!=</span> <span class="ruby-ivar">@encoding</span>
    <span class="ruby-identifier">tokens</span>.<span class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">token</span>,<span class="ruby-operator">|</span> <span class="ruby-identifier">token</span>.<span class="ruby-identifier">value</span>.<span class="ruby-identifier">force_encoding</span>(<span class="ruby-identifier">encoding</span>) }
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">raise</span> <span class="ruby-string">&quot;Expected to consume all bytes while deserializing&quot;</span> <span class="ruby-keyword">unless</span> <span class="ruby-ivar">@io</span>.<span class="ruby-identifier">eof?</span>
  <span class="ruby-constant">YARP</span><span class="ruby-operator">::</span><span class="ruby-constant">ParseResult</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">tokens</span>, <span class="ruby-identifier">comments</span>, <span class="ruby-identifier">errors</span>, <span class="ruby-identifier">warnings</span>, <span class="ruby-ivar">@source</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                          </section>

                <section id="private-instance-5Buntitled-5D-method-details" class="method-section">
                <header>
                <h3>Private Instance Methods</h3>
                </header>

                  <div id="method-i-load_constant" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_constant</span><span
                                class="method-args">(index)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_constant-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 168</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_constant</span>(<span class="ruby-identifier">index</span>)
  <span class="ruby-identifier">constant</span> = <span class="ruby-identifier">constant_pool</span>[<span class="ruby-identifier">index</span>]

  <span class="ruby-keyword">unless</span> <span class="ruby-identifier">constant</span>
    <span class="ruby-identifier">offset</span> = <span class="ruby-identifier">constant_pool_offset</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">index</span> <span class="ruby-operator">*</span> <span class="ruby-value">8</span>
    <span class="ruby-identifier">start</span> = <span class="ruby-identifier">serialized</span>.<span class="ruby-identifier">unpack1</span>(<span class="ruby-string">&quot;L&quot;</span>, <span class="ruby-value">offset:</span> <span class="ruby-identifier">offset</span>)
    <span class="ruby-identifier">length</span> = <span class="ruby-identifier">serialized</span>.<span class="ruby-identifier">unpack1</span>(<span class="ruby-string">&quot;L&quot;</span>, <span class="ruby-value">offset:</span> <span class="ruby-identifier">offset</span> <span class="ruby-operator">+</span> <span class="ruby-value">4</span>)

    <span class="ruby-identifier">constant</span> =
      <span class="ruby-keyword">if</span> <span class="ruby-identifier">start</span>.<span class="ruby-identifier">nobits?</span>(<span class="ruby-value">1</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value">31</span>)
        <span class="ruby-identifier">input</span>.<span class="ruby-identifier">byteslice</span>(<span class="ruby-identifier">start</span>, <span class="ruby-identifier">length</span>).<span class="ruby-identifier">to_sym</span>
      <span class="ruby-keyword">else</span>
        <span class="ruby-identifier">serialized</span>.<span class="ruby-identifier">byteslice</span>(<span class="ruby-identifier">start</span> <span class="ruby-operator">&amp;</span> ((<span class="ruby-value">1</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-value">31</span>) <span class="ruby-operator">-</span> <span class="ruby-value">1</span>), <span class="ruby-identifier">length</span>).<span class="ruby-identifier">to_sym</span>
      <span class="ruby-keyword">end</span>

    <span class="ruby-identifier">constant_pool</span>[<span class="ruby-identifier">index</span>] = <span class="ruby-identifier">constant</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">constant</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_embedded_string" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_embedded_string</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_embedded_string-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 145</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_embedded_string</span>
  <span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>(<span class="ruby-identifier">load_varint</span>).<span class="ruby-identifier">force_encoding</span>(<span class="ruby-identifier">encoding</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_location" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_location</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_location-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 160</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_location</span>
  <span class="ruby-constant">Location</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">source</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">load_varint</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_node" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_node</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_node-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 198</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_node</span>
  <span class="ruby-identifier">type</span> = <span class="ruby-identifier">io</span>.<span class="ruby-identifier">getbyte</span>
  <span class="ruby-identifier">location</span> = <span class="ruby-identifier">load_location</span>

  <span class="ruby-keyword">case</span> <span class="ruby-identifier">type</span>
  <span class="ruby-keyword">when</span> <span class="ruby-value">1</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">AliasGlobalVariableNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">2</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">AliasMethodNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">3</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">AlternationPatternNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">4</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">AndNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">5</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ArgumentsNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">6</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ArrayNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">7</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ArrayPatternNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">8</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">AssocNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">9</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">AssocSplatNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">10</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">BackReferenceReadNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">11</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">BeginNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">12</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">BlockArgumentNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">13</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">BlockLocalVariableNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">14</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">BlockNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_required_constant</span> }, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">15</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">BlockParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_constant</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">16</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">BlockParametersNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">17</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">BreakNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">18</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">CallAndWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">19</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">CallNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">20</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">CallOperatorWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">21</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">CallOrWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">22</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">CapturePatternNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">23</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">CaseNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">24</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ClassNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_required_constant</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">25</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ClassVariableAndWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">26</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ClassVariableOperatorWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">27</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ClassVariableOrWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">28</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ClassVariableReadNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">29</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ClassVariableTargetNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">30</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ClassVariableWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">31</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantAndWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">32</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantOperatorWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">33</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantOrWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">34</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantPathAndWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">35</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantPathNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">36</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantPathOperatorWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">37</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantPathOrWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">38</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantPathTargetNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">39</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantPathWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">40</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantReadNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">41</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantTargetNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">42</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ConstantWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">43</span> <span class="ruby-keyword">then</span>
    <span class="ruby-identifier">load_serialized_length</span>
    <span class="ruby-constant">DefNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_required_constant</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">44</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">DefinedNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">45</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ElseNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">46</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">EmbeddedStatementsNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">47</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">EmbeddedVariableNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">48</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">EnsureNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">49</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">FalseNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">50</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">FindPatternNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">51</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">FlipFlopNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">52</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">FloatNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">53</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ForNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">54</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ForwardingArgumentsNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">55</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ForwardingParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">56</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ForwardingSuperNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">57</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">GlobalVariableAndWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">58</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">GlobalVariableOperatorWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">59</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">GlobalVariableOrWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">60</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">GlobalVariableReadNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">61</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">GlobalVariableTargetNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">62</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">GlobalVariableWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">63</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">HashNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">64</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">HashPatternNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">65</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">IfNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">66</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ImaginaryNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">67</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">68</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InstanceVariableAndWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">69</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InstanceVariableOperatorWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">70</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InstanceVariableOrWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">71</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InstanceVariableReadNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">72</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InstanceVariableTargetNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">73</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InstanceVariableWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">74</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">IntegerNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">75</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InterpolatedMatchLastLineNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">76</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InterpolatedRegularExpressionNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">77</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InterpolatedStringNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_location</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">78</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InterpolatedSymbolNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_location</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">79</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">InterpolatedXStringNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">80</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">KeywordHashNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">81</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">KeywordParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">82</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">KeywordRestParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_constant</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">83</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">LambdaNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_required_constant</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">84</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">LocalVariableAndWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">85</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">LocalVariableOperatorWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">86</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">LocalVariableOrWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">87</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">LocalVariableReadNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">88</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">LocalVariableTargetNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">89</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">LocalVariableWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">90</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">MatchLastLineNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">91</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">MatchPredicateNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">92</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">MatchRequiredNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">93</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">MissingNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">94</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ModuleNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_required_constant</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">95</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">MultiTargetNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">96</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">MultiWriteNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">97</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">NextNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">98</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">NilNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">99</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">NoKeywordsParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">100</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">NumberedReferenceReadNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">101</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">OptionalParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">102</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">OrNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">103</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ParametersNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">104</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ParenthesesNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">105</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">PinnedExpressionNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">106</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">PinnedVariableNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">107</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">PostExecutionNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">108</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">PreExecutionNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">109</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ProgramNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_required_constant</span> }, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">110</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RangeNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">111</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RationalNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">112</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RedoNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">113</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RegularExpressionNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">114</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RequiredDestructuredParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">115</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RequiredParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_required_constant</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">116</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RescueModifierNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">117</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RescueNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">118</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RestParameterNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_constant</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">119</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">RetryNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">120</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">ReturnNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">121</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">SelfNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">122</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">SingletonClassNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_required_constant</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">123</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">SourceEncodingNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">124</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">SourceFileNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">125</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">SourceLineNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">126</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">SplatNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">127</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">StatementsNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">128</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">StringConcatNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">129</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">StringNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">130</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">SuperNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">131</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">SymbolNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">132</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">TrueNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">133</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">UndefNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">134</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">UnlessNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">135</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">UntilNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">136</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">WhenNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-constant">Array</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_varint</span>) { <span class="ruby-identifier">load_node</span> }, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">137</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">WhileNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_node</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">138</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">XStringNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_string</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">139</span> <span class="ruby-keyword">then</span>
    <span class="ruby-constant">YieldNode</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">load_location</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">load_optional_node</span>, <span class="ruby-identifier">load_optional_location</span>, <span class="ruby-identifier">location</span>)
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_optional_constant" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_optional_constant</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_optional_constant-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 193</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_optional_constant</span>
  <span class="ruby-identifier">index</span> = <span class="ruby-identifier">load_varint</span>
  <span class="ruby-identifier">load_constant</span>(<span class="ruby-identifier">index</span> <span class="ruby-operator">-</span> <span class="ruby-value">1</span>) <span class="ruby-keyword">if</span> <span class="ruby-identifier">index</span> <span class="ruby-operator">!=</span> <span class="ruby-value">0</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_optional_location" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_optional_location</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_optional_location-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 164</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_optional_location</span>
  <span class="ruby-identifier">load_location</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">io</span>.<span class="ruby-identifier">getbyte</span> <span class="ruby-operator">!=</span> <span class="ruby-value">0</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_optional_node" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_optional_node</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_optional_node-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 138</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_optional_node</span>
  <span class="ruby-keyword">if</span> <span class="ruby-identifier">io</span>.<span class="ruby-identifier">getbyte</span> <span class="ruby-operator">!=</span> <span class="ruby-value">0</span>
    <span class="ruby-identifier">io</span>.<span class="ruby-identifier">pos</span> <span class="ruby-operator">-=</span> <span class="ruby-value">1</span>
    <span class="ruby-identifier">load_node</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_required_constant" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_required_constant</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_required_constant-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 189</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_required_constant</span>
  <span class="ruby-identifier">load_constant</span>(<span class="ruby-identifier">load_varint</span> <span class="ruby-operator">-</span> <span class="ruby-value">1</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_serialized_length" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_serialized_length</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_serialized_length-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 134</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_serialized_length</span>
  <span class="ruby-identifier">io</span>.<span class="ruby-identifier">read</span>(<span class="ruby-value">4</span>).<span class="ruby-identifier">unpack1</span>(<span class="ruby-string">&quot;L&quot;</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_string" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_string</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_string-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 149</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_string</span>
  <span class="ruby-keyword">case</span> <span class="ruby-identifier">io</span>.<span class="ruby-identifier">getbyte</span>
  <span class="ruby-keyword">when</span> <span class="ruby-value">1</span>
    <span class="ruby-identifier">input</span>.<span class="ruby-identifier">byteslice</span>(<span class="ruby-identifier">load_varint</span>, <span class="ruby-identifier">load_varint</span>).<span class="ruby-identifier">force_encoding</span>(<span class="ruby-identifier">encoding</span>)
  <span class="ruby-keyword">when</span> <span class="ruby-value">2</span>
    <span class="ruby-identifier">load_embedded_string</span>
  <span class="ruby-keyword">else</span>
    <span class="ruby-identifier">raise</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-i-load_varint" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_varint</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>variable-length integer using <a href="https://en.wikipedia.org/wiki/LEB128">en.wikipedia.org/wiki/LEB128</a> This is also what protobuf uses: <a href="https://protobuf.dev/programming-guides/encoding/#varints">protobuf.dev/programming-guides/encoding/#varints</a></p>

                              <div class="method-source-code" id="load_varint-source">
            <pre><span class="ruby-comment"># File yarp/serialize.rb, line 120</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">load_varint</span>
  <span class="ruby-identifier">n</span> = <span class="ruby-identifier">io</span>.<span class="ruby-identifier">getbyte</span>
  <span class="ruby-keyword">if</span> <span class="ruby-identifier">n</span> <span class="ruby-operator">&lt;</span> <span class="ruby-value">128</span>
    <span class="ruby-identifier">n</span>
  <span class="ruby-keyword">else</span>
    <span class="ruby-identifier">n</span> <span class="ruby-operator">-=</span> <span class="ruby-value">128</span>
    <span class="ruby-identifier">shift</span> = <span class="ruby-value">0</span>
    <span class="ruby-keyword">while</span> (<span class="ruby-identifier">b</span> = <span class="ruby-identifier">io</span>.<span class="ruby-identifier">getbyte</span>) <span class="ruby-operator">&gt;=</span> <span class="ruby-value">128</span>
      <span class="ruby-identifier">n</span> <span class="ruby-operator">+=</span> (<span class="ruby-identifier">b</span> <span class="ruby-operator">-</span> <span class="ruby-value">128</span>) <span class="ruby-operator">&lt;&lt;</span> (<span class="ruby-identifier">shift</span> <span class="ruby-operator">+=</span> <span class="ruby-value">7</span>)
    <span class="ruby-keyword">end</span>
    <span class="ruby-identifier">n</span> <span class="ruby-operator">+</span> (<span class="ruby-identifier">b</span> <span class="ruby-operator">&lt;&lt;</span> (<span class="ruby-identifier">shift</span> <span class="ruby-operator">+</span> <span class="ruby-value">7</span>))
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                          </section>

              </section>
              </main>



            </div>  <!--  class='wrapper hdiv' -->


<footer id="validator-badges" role="contentinfo">
<p><a href="https://validator.w3.org/check/referer">Validate</a></p>
<p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.4.0.</p>
<p>Based on <a href="https://github.com/ged/darkfish/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.</p>

  
    <p><p><a href="https://ruby-doc.org">Ruby-doc.org</a> is a service of <a href="https://jamesbritt.com">James Britt</a> and <a href="https://neurogami.com">Neurogami</a>, purveyors of fine <a href='https://jamesbritt.bandcamp.com/'>dance noise</a></p>
</p>
  
  </footer>

<script type="text/javascript">


  let ads  = $("#carbonads-container").children().detach();


  function swapMode() {
    var cookieName = 'darkmode';
    var cssDarkmode = Cookies.get(cookieName);
    console.log("***** swapMode! " + cssDarkmode + " *****");


    if (cssDarkmode == "true") {
      console.log("We have dark mode, set the css to light ...");
      $('#rdoccss').attr("href", defaultModeCssHref);
      $('#cssSelect').text("Dark mode");
      cssDarkmode = "false";
      console.log("swapMode! Now set cookie to " + cssDarkmode);
      Cookies.set(cookieName, cssDarkmode);

    } else {
      console.log("We not have dark mode, set the css to dark ...");
      $('#rdoccss').attr("href", darkModeCsseHref);
      $('#cssSelect').text("Light mode");
      cssDarkmode = "true";
      console.log("swapMode! Now set cookie to " + cssDarkmode);
      Cookies.set(cookieName, cssDarkmode);

    }

    console.log("  --------------- ");
  }


const vueCssApp = new Vue({
el: '#menubar',
data: {
isDark: false
},
methods: {
toggleClass: function(event){
this.isDark = !this.isDark;
}
}
})

const vueApp = new Vue({
el: '#vapp',
data: { 
isOpen: true
},

mounted() {
this.handleResize();
this.manage_mob_classes();
window.addEventListener('resize', this.handleResize)
//this.isOpen !=  (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent));
},
destroyed() {
window.removeEventListener('resize', this.handleResize)
},
created() {
//manage_mob_classes();
},

methods : {
isMobile() {
  return (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent));
},

  handleResize() {
    if (!this.isMobile()) {
      this.isOpen = window.innerWidth > 800;
    }
  },

  manage_mob_classes() {
    if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) {
      $("nav").addClass("mob_nav");
      $("main").addClass("mob_main");
      $("#extraz").addClass("mob_extraz");
      $("#carbonads-container").addClass("mob_carbonads-container");
      this.isOpen  = false;
    } else {
      $("nav").removeClass("mob_nav") 
        $("main").removeClass("mob_main");
      $("#extraz").removeClass("mob_extraz");
      $("#carbonads-container").removeClass("mob_carbonads-container");
      this.isOpen  = true;
    }
  },

  toggleNav() {
    this.isOpen =! this.isOpen ;
    // alert("Toggle nav!");
    console.log("toggleNav() click: " + this.isOpen );
  }
}
})

$("#carbonads-container").append(ads);


$(function() {

    var darkmode = Cookies.get("darkmode");
    console.log("Document ready: " + darkmode);

    if ( darkmode  == "true" ) {
      $('#cssSelect').text("Light mode");
    } else {
      $('#cssSelect').text("Dark mode");
     }

    $('body').css('display','block');
    });

</script>

    
  </body> 
</html>

